home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / print / gs261ini.zip / LIB.DOC < prev    next >
Text File  |  1993-05-12  |  4KB  |  79 lines

  1.    Copyright (C) 1989 Aladdin Enterprises.  All rights reserved.
  2.  
  3. This file is part of Ghostscript.
  4.  
  5. Ghostscript is distributed in the hope that it will be useful, but
  6. WITHOUT ANY WARRANTY.  No author or distributor accepts responsibility
  7. to anyone for the consequences of using it or for whether it serves any
  8. particular purpose or works at all, unless he says so in writing.  Refer
  9. to the Ghostscript General Public License for full details.
  10.  
  11. Everyone is granted permission to copy, modify and redistribute
  12. Ghostscript, but only under the conditions described in the Ghostscript
  13. General Public License.  A copy of this license is supposed to have been
  14. given to you along with Ghostscript so you can know your rights and
  15. responsibilities.  It should be in a file named COPYING.  Among other
  16. things, the copyright notice and this notice must be preserved on all
  17. copies.
  18.  
  19. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  20.  
  21. This file, lib.doc, describes the Ghostscript library, a collection of C
  22. procedures that implement the primitive graphic operations of the
  23. Ghostscript language.
  24.  
  25. For an overview of Ghostscript and a list of the documentation files, see
  26. README.
  27.  
  28. ********
  29. ******** The Ghostscript library ********
  30. ********
  31.  
  32. Ghostscript is actually two programs: a language interpreter, and a
  33. graphics library.  The library provides, in the form of C procedures, all
  34. the graphics functions of the language, i.e., approximately those
  35. facilities listed in section 6.2 of the PostScript manual starting with
  36. the graphics state operators.  In addition, the library provides some
  37. lower-level graphics facilities that offer higher performance in exchange
  38. for less generality.
  39.  
  40. To be specific, the highest level of the library implements all the
  41. operators in the "graphics state", "coordinate system and matrix", "path
  42. construction", "painting", "character and font", and "font cache" sections
  43. of the PostScript manual, with the following deliberate exceptions:
  44.     settransfer, currenttransfer
  45.     definefont, findfont
  46.     FontDirectory, StandardEncoding
  47. The following "device" operators are implemented:
  48.     showpage (synchronizes the display)
  49.     nulldevice
  50.  
  51. There are slight differences in the operators that return multiple values,
  52. since C's provisions for this are awkward.  Also, the control structure
  53. for the operators involving (an) auxiliary procedure(s) (setscreen,
  54. pathforall, image, imagemask) is partly inverted: the client calls a
  55. procedure to set up an enumerator object, and then calls another procedure
  56. for each iteration.  The ...show operators, charpath, and stringwidth
  57. also use an inverted control structure.
  58.  
  59. Files named gs*.c implement the higher level of the graphics library.
  60. To use the facilities of gs?.c, a client program should include
  61. gs?.h.  As might be expected, all procedures, variables, and
  62. structures available at this level begin with gs_.  Structures that
  63. appear in these interfaces, but whose definitions may be hidden from
  64. clients, also have names beginning with gs_, i.e., the prefix
  65. reflects at what level the abstraction is made available, not the
  66. implementation.
  67.  
  68. Files named gx*.c implement the lower level of the graphics library.
  69. To use the facilities of gx?.c, a client program should include
  70. gx?.h.  The interfaces at the gx level are less stable, and expose
  71. more of the implementation detail, than those at the gs level: in
  72. particular, the gx interfaces generally use device coordinates in an
  73. internal fixed-point representation, as opposed to the gs interfaces
  74. that use floating point user coordinates.  Named entities at this
  75. level begin with gx_.
  76.  
  77. Files named gz*.c and gz*.h are internal to the Ghostscript
  78. implementation, and not designed to be called by clients.
  79.